3.308 \(\int \frac{x^2 (d+e x)}{(a^2-c^2 x^2)^2} \, dx\)

Optimal. Leaf size=77 \[ \frac{x (d+e x)}{2 c^2 \left (a^2-c^2 x^2\right )}+\frac{(2 a e+c d) \log (a-c x)}{4 a c^4}-\frac{(c d-2 a e) \log (a+c x)}{4 a c^4} \]

[Out]

(x*(d + e*x))/(2*c^2*(a^2 - c^2*x^2)) + ((c*d + 2*a*e)*Log[a - c*x])/(4*a*c^4) - ((c*d - 2*a*e)*Log[a + c*x])/
(4*a*c^4)

________________________________________________________________________________________

Rubi [A]  time = 0.0488583, antiderivative size = 77, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.13, Rules used = {819, 633, 31} \[ \frac{x (d+e x)}{2 c^2 \left (a^2-c^2 x^2\right )}+\frac{(2 a e+c d) \log (a-c x)}{4 a c^4}-\frac{(c d-2 a e) \log (a+c x)}{4 a c^4} \]

Antiderivative was successfully verified.

[In]

Int[(x^2*(d + e*x))/(a^2 - c^2*x^2)^2,x]

[Out]

(x*(d + e*x))/(2*c^2*(a^2 - c^2*x^2)) + ((c*d + 2*a*e)*Log[a - c*x])/(4*a*c^4) - ((c*d - 2*a*e)*Log[a + c*x])/
(4*a*c^4)

Rule 819

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Simp[((d + e*x)^(
m - 1)*(a + c*x^2)^(p + 1)*(a*(e*f + d*g) - (c*d*f - a*e*g)*x))/(2*a*c*(p + 1)), x] - Dist[1/(2*a*c*(p + 1)),
Int[(d + e*x)^(m - 2)*(a + c*x^2)^(p + 1)*Simp[a*e*(e*f*(m - 1) + d*g*m) - c*d^2*f*(2*p + 3) + e*(a*e*g*m - c*
d*f*(m + 2*p + 2))*x, x], x], x] /; FreeQ[{a, c, d, e, f, g}, x] && NeQ[c*d^2 + a*e^2, 0] && LtQ[p, -1] && GtQ
[m, 1] && (EqQ[d, 0] || (EqQ[m, 2] && EqQ[p, -3] && RationalQ[a, c, d, e, f, g]) ||  !ILtQ[m + 2*p + 3, 0])

Rule 633

Int[((d_) + (e_.)*(x_))/((a_) + (c_.)*(x_)^2), x_Symbol] :> With[{q = Rt[-(a*c), 2]}, Dist[e/2 + (c*d)/(2*q),
Int[1/(-q + c*x), x], x] + Dist[e/2 - (c*d)/(2*q), Int[1/(q + c*x), x], x]] /; FreeQ[{a, c, d, e}, x] && NiceS
qrtQ[-(a*c)]

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rubi steps

\begin{align*} \int \frac{x^2 (d+e x)}{\left (a^2-c^2 x^2\right )^2} \, dx &=\frac{x (d+e x)}{2 c^2 \left (a^2-c^2 x^2\right )}-\frac{\int \frac{a^2 d+2 a^2 e x}{a^2-c^2 x^2} \, dx}{2 a^2 c^2}\\ &=\frac{x (d+e x)}{2 c^2 \left (a^2-c^2 x^2\right )}+\frac{(c d-2 a e) \int \frac{1}{-a c-c^2 x} \, dx}{4 a c^2}-\frac{(c d+2 a e) \int \frac{1}{a c-c^2 x} \, dx}{4 a c^2}\\ &=\frac{x (d+e x)}{2 c^2 \left (a^2-c^2 x^2\right )}+\frac{(c d+2 a e) \log (a-c x)}{4 a c^4}-\frac{(c d-2 a e) \log (a+c x)}{4 a c^4}\\ \end{align*}

Mathematica [A]  time = 0.036751, size = 64, normalized size = 0.83 \[ \frac{\frac{a^2 e+c^2 d x}{a^2-c^2 x^2}+e \log \left (a^2-c^2 x^2\right )-\frac{c d \tanh ^{-1}\left (\frac{c x}{a}\right )}{a}}{2 c^4} \]

Antiderivative was successfully verified.

[In]

Integrate[(x^2*(d + e*x))/(a^2 - c^2*x^2)^2,x]

[Out]

((a^2*e + c^2*d*x)/(a^2 - c^2*x^2) - (c*d*ArcTanh[(c*x)/a])/a + e*Log[a^2 - c^2*x^2])/(2*c^4)

________________________________________________________________________________________

Maple [A]  time = 0.01, size = 118, normalized size = 1.5 \begin{align*}{\frac{ae}{4\,{c}^{4} \left ( cx+a \right ) }}-{\frac{d}{4\,{c}^{3} \left ( cx+a \right ) }}+{\frac{\ln \left ( cx+a \right ) e}{2\,{c}^{4}}}-{\frac{\ln \left ( cx+a \right ) d}{4\,a{c}^{3}}}-{\frac{ae}{4\,{c}^{4} \left ( cx-a \right ) }}-{\frac{d}{4\,{c}^{3} \left ( cx-a \right ) }}+{\frac{\ln \left ( cx-a \right ) e}{2\,{c}^{4}}}+{\frac{\ln \left ( cx-a \right ) d}{4\,a{c}^{3}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2*(e*x+d)/(-c^2*x^2+a^2)^2,x)

[Out]

1/4/c^4/(c*x+a)*a*e-1/4/c^3/(c*x+a)*d+1/2/c^4*ln(c*x+a)*e-1/4/a/c^3*ln(c*x+a)*d-1/4/c^4/(c*x-a)*a*e-1/4/c^3/(c
*x-a)*d+1/2/c^4*ln(c*x-a)*e+1/4/a/c^3*ln(c*x-a)*d

________________________________________________________________________________________

Maxima [A]  time = 1.07014, size = 107, normalized size = 1.39 \begin{align*} -\frac{c^{2} d x + a^{2} e}{2 \,{\left (c^{6} x^{2} - a^{2} c^{4}\right )}} - \frac{{\left (c d - 2 \, a e\right )} \log \left (c x + a\right )}{4 \, a c^{4}} + \frac{{\left (c d + 2 \, a e\right )} \log \left (c x - a\right )}{4 \, a c^{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(e*x+d)/(-c^2*x^2+a^2)^2,x, algorithm="maxima")

[Out]

-1/2*(c^2*d*x + a^2*e)/(c^6*x^2 - a^2*c^4) - 1/4*(c*d - 2*a*e)*log(c*x + a)/(a*c^4) + 1/4*(c*d + 2*a*e)*log(c*
x - a)/(a*c^4)

________________________________________________________________________________________

Fricas [A]  time = 1.59396, size = 235, normalized size = 3.05 \begin{align*} -\frac{2 \, a c^{2} d x + 2 \, a^{3} e -{\left (a^{2} c d - 2 \, a^{3} e -{\left (c^{3} d - 2 \, a c^{2} e\right )} x^{2}\right )} \log \left (c x + a\right ) +{\left (a^{2} c d + 2 \, a^{3} e -{\left (c^{3} d + 2 \, a c^{2} e\right )} x^{2}\right )} \log \left (c x - a\right )}{4 \,{\left (a c^{6} x^{2} - a^{3} c^{4}\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(e*x+d)/(-c^2*x^2+a^2)^2,x, algorithm="fricas")

[Out]

-1/4*(2*a*c^2*d*x + 2*a^3*e - (a^2*c*d - 2*a^3*e - (c^3*d - 2*a*c^2*e)*x^2)*log(c*x + a) + (a^2*c*d + 2*a^3*e
- (c^3*d + 2*a*c^2*e)*x^2)*log(c*x - a))/(a*c^6*x^2 - a^3*c^4)

________________________________________________________________________________________

Sympy [A]  time = 0.762366, size = 109, normalized size = 1.42 \begin{align*} - \frac{a^{2} e + c^{2} d x}{- 2 a^{2} c^{4} + 2 c^{6} x^{2}} + \frac{\left (2 a e - c d\right ) \log{\left (x + \frac{2 a^{2} e - a \left (2 a e - c d\right )}{c^{2} d} \right )}}{4 a c^{4}} + \frac{\left (2 a e + c d\right ) \log{\left (x + \frac{2 a^{2} e - a \left (2 a e + c d\right )}{c^{2} d} \right )}}{4 a c^{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**2*(e*x+d)/(-c**2*x**2+a**2)**2,x)

[Out]

-(a**2*e + c**2*d*x)/(-2*a**2*c**4 + 2*c**6*x**2) + (2*a*e - c*d)*log(x + (2*a**2*e - a*(2*a*e - c*d))/(c**2*d
))/(4*a*c**4) + (2*a*e + c*d)*log(x + (2*a**2*e - a*(2*a*e + c*d))/(c**2*d))/(4*a*c**4)

________________________________________________________________________________________

Giac [A]  time = 1.12963, size = 115, normalized size = 1.49 \begin{align*} -\frac{d x + \frac{a^{2} e}{c^{2}}}{2 \,{\left (c x + a\right )}{\left (c x - a\right )} c^{2}} - \frac{{\left (c d - 2 \, a e\right )} \log \left ({\left | c x + a \right |}\right )}{4 \, a c^{4}} + \frac{{\left (c d + 2 \, a e\right )} \log \left ({\left | c x - a \right |}\right )}{4 \, a c^{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(e*x+d)/(-c^2*x^2+a^2)^2,x, algorithm="giac")

[Out]

-1/2*(d*x + a^2*e/c^2)/((c*x + a)*(c*x - a)*c^2) - 1/4*(c*d - 2*a*e)*log(abs(c*x + a))/(a*c^4) + 1/4*(c*d + 2*
a*e)*log(abs(c*x - a))/(a*c^4)